package com.share.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

import lombok.Data;

import javax.validation.constraints.NotBlank;

/**
 * 
 * @TableName sys_role
 */
@TableName(value ="sys_role")
@Data
public class SysRole implements Serializable {
    /**
     * 
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 
     */
    @TableField(value = "name")
    @NotBlank(message = "角色名不能为空")
    private String name;

    /**
     * 
     */
    @TableField(value = "code")
    @NotBlank(message = "角色编码不能为空")
    private String code;

    /**
     * 备注
     */
    @TableField(value = "remark")
    private String remark;

    /**
     * 
     */
    @TableField(value = "created")
    private Date created;

    /**
     * 
     */
    @TableField(value = "updated")
    private Date updated;

    /**
     * 
     */
    @TableField(value = "statu")
    private Integer statu;

    @TableField(exist = false)
    private List<Long> menuIds = new ArrayList<>();

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}